home *** CD-ROM | disk | FTP | other *** search
Text File | 1995-08-10 | 5.9 KB | 146 lines | [TEXT/MPS ] |
- (*
- File: ControlStrip.mod
-
- Contains: Control Strip (for Powerbooks and Duos) Interfaces.
-
- Version: Technology: System 7.5
- Package: Universal Interfaces 2.0 in “MPW Latest” on ETO #17
-
- Copyright: © 1984-1995 by Apple Computer, Inc.
- All rights reserved.
-
- Bugs?: If you find a problem with this file, use the Apple Bug Reporter
- stack. Include the file and version information (from above)
- in the problem description and send to:
- Internet: apple.bugs.applelink.apple.com
- AppleLink: APPLE.BUGS
-
- *)
-
- (*$TAGS-*)
- (*$CALLING PASCAL*)
- MODULE ControlStrip;
-
- IMPORT SYSTEM, Types, Menus, Dialogs;
-
- (* $PUSH*)
- (* $ALIGN MAC68K*)
- (* $LibExport+*)
-
- CONST
- sdevInitModule* = 0; (* initialize the module*)
- sdevCloseModule* = 1; (* clean up before being closed*)
- sdevFeatures* = 2; (* return feature bits*)
- sdevGetDisplayWidth* = 3; (* returns the width of the module's display*)
- sdevPeriodicTickle* = 4; (* periodic tickle when nothing else is happening*)
- sdevDrawStatus* = 5; (* update the interface in the Control Strip*)
- sdevMouseClick* = 6; (* user clicked on the module's display area in the Control Strip*)
- sdevSaveSettings* = 7; (* saved any changed settings in module's preferences file*)
- sdevShowBalloonHelp* = 8; (* puts up a help balloon, if the module has one to display*)
-
- (*********************************************************************************************
-
- Features supported by the module. If a bit is set, it means that feature is supported.
- All undefined bits are reserved for future use by Apple, and should be set to zero.
-
- *********************************************************************************************)
- sdevWantMouseClicks* = 0; (* notify the module of mouseDown events*)
- sdevDontAutoTrack* = 1; (* call the module to do mouse tracking*)
- sdevHasCustomHelp* = 2; (* module provides its own help messages*)
- sdevKeepModuleLocked* = 3; (* module needs to be locked in the heap*)
-
- (*********************************************************************************************
-
- Result values returned by the sdevPeriodicTickle and sdevIconMouseClick selectors.
- If a bit is set, the module can request that a specific function is performed by
- the Control Strip. A result of zero will do nothing. All undefined bits are reserved
- for future use by Apple, and should be set to zero.
-
- *********************************************************************************************)
- sdevResizeDisplay* = 0; (* resize the module's display*)
- sdevNeedToSave* = 1; (* need to save changed settings, when convenient*)
- sdevHelpStateChange* = 2; (* need to update the help message because of a state change*)
- sdevCloseNow* = 3; (* close a module because it doesn't want to stay around*)
-
- (*********************************************************************************************
-
- miscellaneous
-
- *********************************************************************************************)
- sdevFileType* = LONG("sdev");
-
- sdevMenuItemMark* = '•';
-
- (* direction values for SBDrawBarGraph*)
- BarGraphSlopeLeft* = -1; (* max end of sloping bar graph is on the left*)
- BarGraphFlatRight* = 0; (* max end of flat bar graph is on the right*)
- BarGraphSlopeRight* = 1; (* max end of sloping bar graph is on the right*)
-
- (*********************************************************************************************
-
- utility routines to provide standard interface elements and support for common functions
-
- *********************************************************************************************)
-
- PROCEDURE SBIsControlStripVisible*(): BOOLEAN;
- (*$IF NOT GENERATINGCFM*)
- INLINE PASCAL $7000, $AAF2;
- (*$END*)
- PROCEDURE SBShowHideControlStrip*(showIt: BOOLEAN);
- (*$IF NOT GENERATINGCFM*)
- INLINE PASCAL $303C, $0101, $AAF2;
- (*$END*)
- PROCEDURE SBSafeToAccessStartupDisk*(): BOOLEAN;
- (*$IF NOT GENERATINGCFM*)
- INLINE PASCAL $7002, $AAF2;
- (*$END*)
- PROCEDURE SBOpenModuleResourceFile*(fileCreator: Types.OSType): INTEGER;
- (*$IF NOT GENERATINGCFM*)
- INLINE PASCAL $303C, $0203, $AAF2;
- (*$END*)
- PROCEDURE SBLoadPreferences*(prefsResourceName: Types.ConstStr255Param; VAR preferences: Types.Handle): Types.OSErr;
- (*$IF NOT GENERATINGCFM*)
- INLINE PASCAL $303C, $0404, $AAF2;
- (*$END*)
- PROCEDURE SBSavePreferences*(prefsResourceName: Types.ConstStr255Param; preferences: Types.Handle): Types.OSErr;
- (*$IF NOT GENERATINGCFM*)
- INLINE PASCAL $303C, $0405, $AAF2;
- (*$END*)
- PROCEDURE SBGetDetachedIndString*(theString: Types.StringPtr; stringList: Types.Handle; whichString: INTEGER);
- (*$IF NOT GENERATINGCFM*)
- INLINE PASCAL $303C, $0506, $AAF2;
- (*$END*)
- PROCEDURE SBGetDetachIconSuite*(VAR theIconSuite: Types.Handle; theResID: INTEGER; selector: LONGINT): Types.OSErr;
- (*$IF NOT GENERATINGCFM*)
- INLINE PASCAL $303C, $0507, $AAF2;
- (*$END*)
- PROCEDURE SBTrackPopupMenu*((*CONST*)VAR moduleRect: Types.Rect; theMenu: Menus.MenuHandle): Types.OSErr;
- (*$IF NOT GENERATINGCFM*)
- INLINE PASCAL $303C, $0408, $AAF2;
- (*$END*)
- PROCEDURE SBTrackSlider*((*CONST*)VAR moduleRect: Types.Rect; ticksOnSlider: INTEGER; initialValue: INTEGER): Types.OSErr;
- (*$IF NOT GENERATINGCFM*)
- INLINE PASCAL $303C, $0409, $AAF2;
- (*$END*)
- PROCEDURE SBShowHelpString*((*CONST*)VAR moduleRect: Types.Rect; helpString: Types.StringPtr): Types.OSErr;
- (*$IF NOT GENERATINGCFM*)
- INLINE PASCAL $303C, $040A, $AAF2;
- (*$END*)
- PROCEDURE SBGetBarGraphWidth*(barCount: INTEGER): INTEGER;
- (*$IF NOT GENERATINGCFM*)
- INLINE PASCAL $303C, $010B, $AAF2;
- (*$END*)
- PROCEDURE SBDrawBarGraph*(level: INTEGER; barCount: INTEGER; direction: INTEGER; barGraphTopLeft: Types.Point);
- (*$IF NOT GENERATINGCFM*)
- INLINE PASCAL $303C, $050C, $AAF2;
- (*$END*)
- PROCEDURE SBModalDialogInContext*(filterProc: Dialogs.ModalFilterUPP; VAR itemHit: INTEGER);
- (*$IF NOT GENERATINGCFM*)
- INLINE PASCAL $303C, $040D, $AAF2;
- (*$END*)
-
- (* $ALIGN RESET*)
- (* $POP*)
-
- END ControlStrip.
-